document.writeln("<!DOCTYPE html>");
document.writeln("<html>");
document.writeln("	<head>");
document.writeln("		<meta charset=\'utf-8\'>");
document.writeln("		<title></title>");
document.writeln("		<meta name=\'viewport\' content=\'width=device-width,initial-scale=1,user-scalable=0\'>");
document.writeln("		<link href=\'https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css\' rel=\'stylesheet\'>");
document.writeln("		<link rel=\'stylesheet\' type=\'text/css\' href=\'./css/sidebar.css\'/>");
document.writeln("		<link rel=\'stylesheet\' type=\'text/css\' href=\'./css/basestyle.css\'/>");
document.writeln("		<script src=\'js/base.js\'></script>");
document.writeln("	</head>");
document.writeln("	<body>");
document.writeln("				<div id=\'sidebar\'>");
document.writeln("					<div ref=\'disappear\' style=\'display: none;\'>");
document.writeln("						<!-- 作品追踪 -->");
document.writeln("						<div class=\'works\'>");
document.writeln("							<div class=\'workstitle\'>");
document.writeln("								<div class=\'workstitletxt\'>");
document.writeln("									<p v-show=\'languagestatus == 1\'>竞赛中心</p>");
document.writeln("									<p v-show=\'languagestatus == 2\'>Competition tracking</p>");
document.writeln("								</div>");
document.writeln("								<div class=\'workstitlemore\'>");
document.writeln("									<div class=\'workstitlemoretxt\'>");
document.writeln("										<a href=\'jingsaicenter.html\'>");
document.writeln("											<p v-show=\'languagestatus == 1\'>查看更多</p>");
document.writeln("											<p v-show=\'languagestatus == 2\'>See more</p>");
document.writeln("										</a>");
document.writeln("									</div>");
document.writeln("									<div class=\'workstitlemoreimg\'>");
document.writeln("										<img src=\'./images/more.png\'>");
document.writeln("									</div>");
document.writeln("								</div>");
document.writeln("								<div class=\'clear\'></div>");
document.writeln("							</div>");
document.writeln("							<div class=\'\'>");
document.writeln("								<div class=\'worksproduction\' v-for=\'(best,index) in bestlist\' @click=\'openworkdetail(best.id)\'>");
document.writeln("									<div class=\'worksproductionimg\'>");
document.writeln("										<img :src=\'best.image\'>");
document.writeln("									</div>");
document.writeln("									<div class=\'worksproductionnav\'>");
document.writeln("										<div class=\'worksproductionnavtitle\'>");
document.writeln("											<p v-show=\'languagestatus == 1\'>{{best.title}}</p>");
document.writeln("										</div>");
document.writeln("										<div class=\'worksproductionnavwarp\'>");
document.writeln("											<div class=\'worksproductionnavwarpfabu workeritem\'>");
document.writeln("												<div class=\'workeritemtxt\'>");
document.writeln("													<p v-show=\'languagestatus == 1\'>截止日期：</p>");
document.writeln("													<p v-show=\'languagestatus == 2\'>closing date：</p>");
document.writeln("													<p>{{best.endtime}}</p>");
document.writeln("												</div>");
document.writeln("												<div class=\'workeritemcol\' @click.stop=\'sidecollection(index,best.id,best.collstatus)\'>");
document.writeln("													<img v-show=\'best.collstatus == 0\' src=\'./images/weishoucnag.png\' >");
document.writeln("													<img v-show=\'best.collstatus == 1\' src=\'./images/yishoucang.png\' >");
document.writeln("												</div>");
document.writeln("											</div>");
document.writeln("											<div class=\'worksproductionnavwarpsheji workeritem\'>");
document.writeln("												<p v-show=\'languagestatus == 1\'>发布者：</p>");
document.writeln("												<p v-show=\'languagestatus == 2\'>Publisher：</p>");
document.writeln("												<p>{{best.nickname}}</p>");
document.writeln("											</div>");
document.writeln("										</div>");
document.writeln("									</div>");
document.writeln("								</div>");
document.writeln("							</div>");
document.writeln("						</div>");
document.writeln("						<div class=\'explain\'>");
document.writeln("							<div class=\'explaintitle\'>");
document.writeln("								<p v-show=\'languagestatus == 1\'>{{liucheng.title}}</p>");
document.writeln("								<p v-show=\'languagestatus == 2\'>{{liucheng.titleE}}</p>");
document.writeln("							</div>");
document.writeln("							<div class=\'line\'></div>");
document.writeln("							<div class=\'explainwarp\'>");
document.writeln("								<div style=\'white-space: pre-wrap;\' v-show=\'languagestatus == 1\'>{{liucheng.message}}</div>");
document.writeln("								<div style=\'white-space: pre-wrap;\' v-show=\'languagestatus == 2\'>{{liucheng.messageE}}</div>");
document.writeln("							</div>");
document.writeln("						</div>");
document.writeln("						<div class=\'ad1 aditem\' >");
document.writeln("							<div class=\'aditemsider\' v-for=\'(sidead , index) in sideadlist\' @click=\'opensideaddetail(index,sidead.id,sidead.sheji_competition_id,sidead.adstype)\'>");
document.writeln("								<img :src=\'sidead.image\'>");
document.writeln("							</div>");
document.writeln("							<div class=\'aditemsider\' v-for=\'(userad , index) in useradlist\' @click=\'opensideaddetail(index,userad.id,sidead.sheji_competition_id,userad.adstype)\'>");
document.writeln("								<img :src=\'userad.image\'>");
document.writeln("							</div>");
document.writeln("						</div>");
document.writeln("						<div ref=\'hidepopup\' style=\'display: none;\'>");
document.writeln("							<div class=\'judgepopup\' v-show=\'tanchuang == 1\'>");
document.writeln("								<div class=\'judgepopupnav\'>");
document.writeln("									<div class=\'judgepopupwarp\'>");
document.writeln("										<div class=\'judgepopupwarpup\'>");
document.writeln("											<img src=\'./images/revoke_logo.png\'>");
document.writeln("										</div>");
document.writeln("										<div class=\'judgepopupwarpdown\'>");
document.writeln("											<div class=\'judgepopupwarptxt\'>");
document.writeln("												<p v-show=\'languagestatus == 1\'>您还未登录，请先登录在进行点赞吧!</p>");
document.writeln("												<p v-show=\'languagestatus == 2\'>You haven\'t logged in yet, please log in to collect first!</p>");
document.writeln("											</div>");
document.writeln("											<div class=\'judgepopupwarpbtn\'>");
document.writeln("												<div class=\'judgepopupwarpbtnitem judgepopupwarpbtnactive\' @click=\'closetipopup\'>");
document.writeln("													<p v-show=\'languagestatus == 1\'>好的</p>");
document.writeln("													<p v-show=\'languagestatus == 2\'>OK</p>");
document.writeln("												</div>");
document.writeln("											</div>");
document.writeln("										</div>");
document.writeln("									</div>");
document.writeln("								</div>");
document.writeln("							</div>");
document.writeln("						</div>");
document.writeln("					</div>");
document.writeln("				</div>");
document.writeln("		<script src=\'https://cdn.bootcdn.net/ajax/libs/axios/0.21.0/axios.min.js\'></script>");
document.writeln("		<script src=\'https://cdn.jsdelivr.net/npm/vue/dist/vue.js\'></script>");
document.writeln("		<script type=\'text/javascript\'>");
document.writeln("			let sidebar = new Vue({");
document.writeln("				el: \'#sidebar\',");
document.writeln("				data: {");
document.writeln("					bestlist: [],");
document.writeln("					sideadlist: [],");
document.writeln("					useradlist:[],");
document.writeln("					userid: \'\',");
document.writeln("					token: \'\',");
document.writeln("					tanchuang:0,");
document.writeln("					languagestatus:\'\',");
document.writeln("					liucheng:\'\'");
document.writeln("				},");
document.writeln("				created:function() {");
document.writeln("					this.getsideadlist()");
document.writeln("					if (sessionStorage.getItem(\'languagestatus\')) {");
document.writeln("						let languagestatus = sessionStorage.getItem(\'languagestatus\')");
document.writeln("						this.languagestatus = languagestatus");
document.writeln("					}");
document.writeln("				},");
document.writeln("				mounted:function() {");
document.writeln("					let that = this");
document.writeln("					if (localStorage.getItem(\'logininfo\')) {");
document.writeln("						console.log(\'isdfksjdf sd\')");
document.writeln("						let obj = JSON.parse(localStorage.getItem(\'logininfo\'));");
document.writeln("						console.log(obj)");
document.writeln("						that.loginstatus = 1");
document.writeln("						that.userid = obj.userid");
document.writeln("						that.token = obj.token");
document.writeln("					}");
document.writeln("					this.getbestlist()");
document.writeln("					this.getliucheng()");
document.writeln("					this.$refs.disappear.style.display = \'block\'");
document.writeln("				},");
document.writeln("				methods: {");
document.writeln("					// 时间");
document.writeln("					add0(m){return m<10?\'0\'+m:m },");
document.writeln("					getLocalTime(nS) {");
document.writeln("					   let time = new Date(parseInt(nS)*1000);");
document.writeln("					   var y = time.getFullYear();");
document.writeln("					   var m = time.getMonth()+1;");
document.writeln("					   var d = time.getDate();");
document.writeln("					   var h = time.getHours();");
document.writeln("					   var mm = time.getMinutes();");
document.writeln("					   var s = time.getSeconds();");
document.writeln("					   return y+\'-\'+this.add0(m)+\'-\'+this.add0(d)+\' \'+this.add0(h)+\':\'+this.add0(mm);");
document.writeln("					},");
document.writeln("					// 竞赛追踪");
document.writeln("					getbestlist: function() {");
document.writeln("						let that = this");
document.writeln("						axios.get(\'http://127.0.0.1:8080/api/bishe.competition/sideIndex\', {");
document.writeln("								params: {");
document.writeln("									userid: that.userid,");
document.writeln("									token: that.token");
document.writeln("								}");
document.writeln("							})");
document.writeln("							.then((res) => {");
document.writeln("								console.log(res)");
document.writeln("								if(res.data.code == 1){");
document.writeln("									that.bestlist = res.data.data.competition");
document.writeln("									let list = res.data.data.competition");
document.writeln("									list.forEach((item,index) =>{");
document.writeln("										item.endtime = that.getLocalTime(item.endtime)");
document.writeln("									})");
document.writeln("								}");
document.writeln("							})");
document.writeln("					},");
document.writeln("					// 流程说明");
document.writeln("					getliucheng: function() {");
document.writeln("						let that = this");
document.writeln("						axios.get(\'http://127.0.0.1:8080/api/bishe.about/explain\', {");
document.writeln("								");
document.writeln("							})");
document.writeln("							.then((res) => {");
document.writeln("								console.log(res)");
document.writeln("								if(res.data.code == 1){");
document.writeln("									that.liucheng = res.data.data.explain");
document.writeln("								}");
document.writeln("							})");
document.writeln("					},");
document.writeln("					// 广告位");
document.writeln("					getsideadlist: function() {");
document.writeln("						let that = this");
document.writeln("						axios.get(\'http://127.0.0.1:8080/api/bishe.index/sideads\', {");
document.writeln("			");
document.writeln("							})");
document.writeln("							.then((res) => {");
document.writeln("								console.log(res)");
document.writeln("								that.sideadlist = res.data.data.sideads");
document.writeln("								that.useradlist = res.data.data.userads");
document.writeln("							})");
document.writeln("					},");
document.writeln("					//竞赛追踪详情");
document.writeln("					openworkdetail: function(id) {");
document.writeln("						// console.log(11)");
document.writeln("						let that = this");
document.writeln("						window.location.href = \'jingsaidetail.html?id=\'+id");
document.writeln("					},");
document.writeln("					// 收藏、取消");
document.writeln("					sidecollection:function(i,id,typeids){");
document.writeln("						let that = this");
document.writeln("						let list = that.bestlist");
document.writeln("						if(typeids == 1){");
document.writeln("							typeids = 0");
document.writeln("						}else if(typeids == 0){");
document.writeln("							typeids = 1");
document.writeln("						}");
document.writeln("						axios.get(\'http://127.0.0.1:8080/api/bishe.competition/collection\',{");
document.writeln("							params:{");
document.writeln("								userid:that.userid,");
document.writeln("								token:that.token,");
document.writeln("								id:id,");
document.writeln("								type:typeids,");
document.writeln("							}");
document.writeln("						})");
document.writeln("						.then((res) =>{");
document.writeln("							if(res.data.code == 1){");
document.writeln("								list.forEach((item, index) => {");
document.writeln("									if (index == i && item.collstatus == 1) {");
document.writeln("										item.collstatus = 0");
document.writeln("									} else if (index == i && item.collstatus == 0) {");
document.writeln("										item.collstatus = 1");
document.writeln("									}");
document.writeln("								})");
document.writeln("								that.bestlist = list");
document.writeln("							}else if(res.data.code == 2){");
document.writeln("								that.tanchuang = 1");
document.writeln("							}");
document.writeln("							console.log(res)");
document.writeln("						})");
document.writeln("					},");
document.writeln("					// 广告详情");
document.writeln("					opensideaddetail:function(i,id,raceid,adstype){");
document.writeln("						let that = this");
document.writeln("						if(adstype == 1){");
document.writeln("							axios.get(\'http://127.0.0.1:8080/api/bishe.index/homedetail\',{");
document.writeln("								params:{");
document.writeln("									userid:that.userid,");
document.writeln("									token:that.token,");
document.writeln("									id:id,");
document.writeln("								}");
document.writeln("							})");
document.writeln("							.then((res) =>{");
document.writeln("								window.location.href = \'jingsaidetail.html?id=\'+raceid");
document.writeln("							})");
document.writeln("						}else if(adstype == 0){");
document.writeln("							axios.get(\'http://127.0.0.1:8080/api/bishe.index/homedetail\',{");
document.writeln("								params:{");
document.writeln("									id:id");
document.writeln("								}");
document.writeln("							})");
document.writeln("							.then((res) =>{");
document.writeln("								window.location.href = \'bannerdetail.html?id=\'+that.sideadlist[i].id+\'&adstype=\'+1");
document.writeln("							})");
document.writeln("						}");
document.writeln("					},");
document.writeln("					closetipopup:function(){");
document.writeln("						this.tanchuang = 0");
document.writeln("					}");
document.writeln("				}");
document.writeln("			})");
document.writeln("		</script>");
document.writeln("	</body>");
document.writeln("</html>");